package ee.tlnk.model;

import java.io.Serializable;
import java.sql.Date;
import java.sql.Time;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;


/**
 * The Class OrderModel.
 */
@Entity
@Table(name="orders")
public class OrderModel implements Serializable {

	/** The Constant serialVersionUID. */
	private static final long serialVersionUID = 7678332228876411532L;
		
	/** The id. */
	@Id
	@Column(name = "id")
	@GeneratedValue
	private Integer id;
	

	/** The manager. */
	@ManyToOne
	  @JoinColumn(name="manager_id")
	  private AccountModel manager;

	  
	  /** The room. */
  	@ManyToOne
	  @JoinColumn(name="room_id")
	  private RoomModel room;
	  
		/** The day. */
		@Column(name = "date")
		private Date day;
		

		/** The start. */
		@Column(name = "begin")
		private Time start;
		
		/** The end. */
		@Column(name = "end")
		private Time end;
		
		/**
		 * Gets the id.
		 *
		 * @return the id
		 */
		public Integer getId() {
			return id;
		}

		/**
		 * Sets the id.
		 *
		 * @param id the id to set
		 */
		public void setId(Integer id) {
			this.id = id;
		}

		/**
		 * Gets the manager.
		 *
		 * @return the manager
		 */
		public AccountModel getManager() {
			return manager;
		}

		/**
		 * Sets the manager.
		 *
		 * @param manager the manager to set
		 */
		public void setManager(AccountModel manager) {
			this.manager = manager;
		}

		/**
		 * Gets the room.
		 *
		 * @return the room
		 */
		public RoomModel getRoom() {
			return room;
		}

		/**
		 * Sets the room.
		 *
		 * @param room the room to set
		 */
		public void setRoom(RoomModel room) {
			this.room = room;
		}

		/**
		 * Gets the day.
		 *
		 * @return the day
		 */
		public Date getDay() {
			return day;
		}

		/**
		 * Sets the day.
		 *
		 * @param day the day to set
		 */
		public void setDay(Date day) {
			this.day = day;
		}

		/**
		 * Gets the start.
		 *
		 * @return the start
		 */
		public Time getStart() {
			return start;
		}

		/**
		 * Sets the start.
		 *
		 * @param start the start to set
		 */
		public void setStart(Time start) {
			this.start = start;
		}

		/**
		 * Gets the end.
		 *
		 * @return the end
		 */
		public Time getEnd() {
			return end;
		}

		/**
		 * Sets the end.
		 *
		 * @param end the end to set
		 */
		public void setEnd(Time end) {
			this.end = end;
		}


}
